home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 July: Mac OS SDK / Dev.CD Jul 97 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Interfaces / AIncludes / CMICCProfile.a < prev    next >
Encoding:
Text File  |  1996-01-24  |  25.8 KB  |  688 lines  |  [TEXT/MPS ]

  1. ;
  2. ;    File:        CMICCProfile.a
  3. ;
  4. ;    Contains:    Definitions for ColorSync 2.0 profile
  5. ;
  6. ;    Version:    Technology:    ColorSync 2.0
  7. ;                Package:    Universal Interfaces 2.2 in “MPW” on ETO #20
  8. ;
  9. ;    Copyright:    © 1984-1995 by Apple Computer, Inc.
  10. ;                All rights reserved.
  11. ;
  12. ;    Bugs?:        If you find a problem with this file, use the Apple Bug Reporter
  13. ;                stack.  Include the file and version information (from above)
  14. ;                in the problem description and send to:
  15. ;                    Internet:    apple.bugs@applelink.apple.com
  16. ;                    AppleLink:    APPLE.BUGS
  17. ;
  18. ;
  19.  
  20.     IF &TYPE('__CMICCPROFILE__') = 'UNDEFINED' THEN
  21. __CMICCPROFILE__ SET 1
  22.  
  23.  
  24.     IF &TYPE('__TYPES__') = 'UNDEFINED' THEN
  25.     include 'Types.a'
  26.     ENDIF
  27. ;        include 'ConditionalMacros.a'                                ;
  28.  
  29. cmCS2ProfileVersion                EQU        $02000000
  30.  
  31. ; Current Major version number 
  32. cmCurrentProfileMajorVersion    EQU        $02000000
  33.  
  34. ; magic cookie number for anonymous file ID 
  35. cmMagicNumber                    EQU        'acsp'
  36.  
  37. ; ColorSync profile version 1.0 
  38. cmCS1ProfileVersion                EQU        $00000100
  39.  
  40. ;**********************************************************************
  41. ;************** ColorSync 2.0 profile specification *******************
  42. ;**********************************************************************
  43. ; profile flags element values 
  44. cmEmbeddedProfile                EQU        0                    ; 0 is not embedded profile, 1 is embedded profile 
  45. cmEmbeddedUse                    EQU        1                    ; 0 is to use anywhere, 1 is to use as embedded profile only 
  46.  
  47. ; data type element values 
  48. cmAsciiData                        EQU        0
  49. cmBinaryData                    EQU        1
  50.  
  51. ; rendering intent element values  
  52. cmPerceptual                    EQU        0                    ; Photographic images 
  53. cmRelativeColorimetric            EQU        1                    ; Logo Colors 
  54. cmSaturation                    EQU        2                    ; Business graphics 
  55. cmAbsoluteColorimetric            EQU        3                    ; Logo Colors 
  56.  
  57. ; speed and quality flag options 
  58. cmNormalMode                    EQU        0                    ; it uses the least significent two bits in the high word of flag 
  59. cmDraftMode                        EQU        1                    ; it should be evaulated like this: right shift 16 bits first, mask off the 
  60. cmBestMode                        EQU        2                    ; high 14 bits, and then compare with the enum to determine the option value 
  61.  
  62. ; device/media attributes element values  
  63. cmReflective                    EQU        0                    ; 0 is reflective media, 1 is transparency media 
  64. cmGlossy                        EQU        1                    ; 0 is glossy, 1 is matte 
  65.  
  66. ; screen encodings  
  67. cmPrtrDefaultScreens            EQU        0                    ; Use printer default screens.  0 is false, 1 is ture 
  68. cmLinesPer                        EQU        1                    ; 0 is LinesPerCm, 1 is LinesPerInch 
  69.  
  70. ; 2.0 tag type information 
  71. cmNumHeaderElements                EQU        10
  72.  
  73. ; public tags 
  74. cmAToB0Tag                        EQU        'A2B0'
  75. cmAToB1Tag                        EQU        'A2B1'
  76. cmAToB2Tag                        EQU        'A2B2'
  77. cmBlueColorantTag                EQU        'bXYZ'
  78. cmBlueTRCTag                    EQU        'bTRC'
  79. cmBToA0Tag                        EQU        'B2A0'
  80. cmBToA1Tag                        EQU        'B2A1'
  81. cmBToA2Tag                        EQU        'B2A2'
  82. cmCalibrationDateTimeTag        EQU        'calt'
  83. cmCharTargetTag                    EQU        'targ'
  84. cmCopyrightTag                    EQU        'cprt'
  85. cmDeviceMfgDescTag                EQU        'dmnd'
  86. cmDeviceModelDescTag            EQU        'dmdd'
  87. cmGamutTag                        EQU        'gamt'
  88. cmGrayTRCTag                    EQU        'kTRC'
  89. cmGreenColorantTag                EQU        'gXYZ'
  90. cmGreenTRCTag                    EQU        'gTRC'
  91. cmLuminanceTag                    EQU        'lumi'
  92. cmMeasurementTag                EQU        'meas'
  93. cmMediaBlackPointTag            EQU        'bkpt'
  94. cmMediaWhitePointTag            EQU        'wtpt'
  95. cmNamedColorTag                    EQU        'ncol'
  96. cmPreview0Tag                    EQU        'pre0'
  97. cmPreview1Tag                    EQU        'pre1'
  98. cmPreview2Tag                    EQU        'pre2'
  99. cmProfileDescriptionTag            EQU        'desc'
  100. cmProfileSequenceDescTag        EQU        'pseq'
  101. cmPS2CRD0Tag                    EQU        'psd0'
  102. cmPS2CRD1Tag                    EQU        'psd1'
  103. cmPS2CRD2Tag                    EQU        'psd2'
  104. cmPS2CRD3Tag                    EQU        'psd3'
  105. cmPS2CSATag                        EQU        'ps2s'
  106. cmPS2RenderingIntentTag            EQU        'ps2i'
  107. cmRedColorantTag                EQU        'rXYZ'
  108. cmRedTRCTag                        EQU        'rTRC'
  109. cmScreeningDescTag                EQU        'scrd'
  110. cmScreeningTag                    EQU        'scrn'
  111. cmTechnologyTag                    EQU        'tech'
  112. cmUcrBgTag                        EQU        'bfd '
  113. cmViewingConditionsDescTag        EQU        'vued'
  114. cmViewingConditionsTag            EQU        'view'
  115.  
  116. ; custom tags 
  117. cmPS2CRDVMSizeTag                EQU        'psvm'
  118.  
  119. ; technology tag descriptions 
  120. cmTechnologyFilmScanner            EQU        'fscn'
  121. cmTechnologyReflectiveScanner    EQU        'rscn'
  122. cmTechnologyInkJetPrinter        EQU        'ijet'
  123. cmTechnologyThermalWaxPrinter    EQU        'twax'
  124. cmTechnologyElectrophotographicPrinter EQU        'epho'
  125. cmTechnologyElectrostaticPrinter EQU        'esta'
  126. cmTechnologyDyeSublimationPrinter EQU        'dsub'
  127. cmTechnologyPhotographicPaperPrinter EQU        'rpho'
  128. cmTechnologyFilmWriter            EQU        'fprn'
  129. cmTechnologyVideoMonitor        EQU        'vidm'
  130. cmTechnologyVideoCamera            EQU        'vidc'
  131. cmTechnologyProjectionTelevision EQU        'pjtv'
  132. cmTechnologyCRTDisplay            EQU        'CRT '
  133. cmTechnologyPMDisplay            EQU        'PMD '
  134. cmTechnologyAMDisplay            EQU        'AMD '
  135. cmTechnologyPhotoCD                EQU        'KPCD'
  136. cmTechnologyPhotoImageSetter    EQU        'imgs'
  137. cmTechnologyGravure                EQU        'grav'
  138. cmTechnologyOffsetLithography    EQU        'offs'
  139. cmTechnologySilkscreen            EQU        'silk'
  140. cmTechnologyFlexography            EQU        'flex'
  141.  
  142. ; type signatures 
  143. cmSigCurveType                    EQU        'curv'
  144. cmSigDataType                    EQU        'data'
  145. cmSigDateTimeType                EQU        'dtim'
  146. cmSigLut16Type                    EQU        'mft2'
  147. cmSigLut8Type                    EQU        'mft1'
  148. cmSigMeasurementType            EQU        'meas'
  149. cmSigNamedColorType                EQU        'ncol'
  150. cmSigProfileDescriptionType        EQU        'desc'
  151. cmSigScreeningType                EQU        'scrn'
  152. cmSigS15Fixed16Type                EQU        'sf32'
  153. cmSigSignatureType                EQU        'sig '
  154. cmSigTextType                    EQU        'text'
  155. cmSigU16Fixed16Type                EQU        'uf32'
  156. cmSigU1Fixed15Type                EQU        'uf16'
  157. cmSigUInt32Type                    EQU        'ui32'
  158. cmSigUInt64Type                    EQU        'ui64'
  159. cmSigUInt8Type                    EQU        'ui08'
  160. cmSigViewingConditionsType        EQU        'view'
  161. cmSigXYZType                    EQU        'XYZ '
  162.  
  163. ; Measurement type encodings 
  164. ; Measurement Flare 
  165. cmFlare0                        EQU        $00000000
  166. cmFlare100                        EQU        $00000001
  167.  
  168. ; Measurement Geometry    
  169. cmGeometryUnknown                EQU        $00000000
  170. cmGeometry045or450                EQU        $00000001
  171. cmGeometry0dord0                EQU        $00000002
  172.  
  173. ; Standard Observer    
  174. cmStdobsUnknown                    EQU        $00000000
  175. cmStdobs1931TwoDegrees            EQU        $00000001
  176. cmStdobs1964TenDegrees            EQU        $00000002
  177.  
  178. ; Standard Illuminant 
  179. cmIlluminantUnknown                EQU        $00000000
  180. cmIlluminantD50                    EQU        $00000001
  181. cmIlluminantD65                    EQU        $00000002
  182. cmIlluminantD93                    EQU        $00000003
  183. cmIlluminantF2                    EQU        $00000004
  184. cmIlluminantD55                    EQU        $00000005
  185. cmIlluminantA                    EQU        $00000006
  186. cmIlluminantEquiPower            EQU        $00000007
  187. cmIlluminantF8                    EQU        $00000008
  188.  
  189. ; Spot Function Value 
  190. cmSpotFunctionUnknown            EQU        0
  191. cmSpotFunctionDefault            EQU        1
  192. cmSpotFunctionRound                EQU        2
  193. cmSpotFunctionDiamond            EQU        3
  194. cmSpotFunctionEllipse            EQU        4
  195. cmSpotFunctionLine                EQU        5
  196. cmSpotFunctionSquare            EQU        6
  197. cmSpotFunctionCross                EQU        7
  198.  
  199. ; Color Space Signatures 
  200. cmXYZData                        EQU        'XYZ '
  201. cmLabData                        EQU        'Lab '
  202. cmLuvData                        EQU        'Luv '
  203. cmYxyData                        EQU        'Yxy '
  204. cmRGBData                        EQU        'RGB '
  205. cmGrayData                        EQU        'GRAY'
  206. cmHSVData                        EQU        'HSV '
  207. cmHLSData                        EQU        'HLS '
  208. cmCMYKData                        EQU        'CMYK'
  209. cmCMYData                        EQU        'CMY '
  210. cmMCH5Data                        EQU        'MCH5'
  211. cmMCH6Data                        EQU        'MCH6'
  212. cmMCH7Data                        EQU        'MCH7'
  213. cmMCH8Data                        EQU        'MCH8'
  214.  
  215. ; profileClass enumerations 
  216. cmInputClass                    EQU        'scnr'
  217. cmDisplayClass                    EQU        'mntr'
  218. cmOutputClass                    EQU        'prtr'
  219. cmLinkClass                        EQU        'link'
  220. cmAbstractClass                    EQU        'abst'
  221. cmColorSpaceClass                EQU        'spac'
  222.  
  223. ; platform enumerations 
  224. cmMacintosh                        EQU        'APPL'
  225. cmMicrosoft                        EQU        'MSFT'
  226. cmSolaris                        EQU        'SUNW'
  227. cmSiliconGraphics                EQU        'SGI '
  228. cmTaligent                        EQU        'TGNT'
  229.  
  230. ; ColorSync 1.0 elements 
  231. cmCS1ChromTag                    EQU        'chrm'
  232. cmCS1TRCTag                        EQU        'trc '
  233. cmCS1NameTag                    EQU        'name'
  234. cmCS1CustTag                    EQU        'cust'
  235.  
  236. ; General element data types 
  237. CMDateTime                 RECORD    0
  238. year                     ds.w   1        ; offset: $0 (0)
  239. month                     ds.w   1        ; offset: $2 (2)
  240. dayOfTheMonth             ds.w   1        ; offset: $4 (4)
  241. hours                     ds.w   1        ; offset: $6 (6)
  242. minutes                     ds.w   1        ; offset: $8 (8)
  243. seconds                     ds.w   1        ; offset: $A (10)
  244. sizeof                     EQU *            ; size:   $C (12)
  245.                         ENDR
  246.  
  247. ; typedef struct CMDateTime  CMDateTime
  248. CMFixedXYZColor         RECORD    0
  249. X                         ds.l   1        ; offset: $0 (0)
  250. Y                         ds.l   1        ; offset: $4 (4)
  251. Z                         ds.l   1        ; offset: $8 (8)
  252. sizeof                     EQU *            ; size:   $C (12)
  253.                         ENDR
  254.  
  255. ; typedef struct CMFixedXYZColor  CMFixedXYZColor
  256. ; typedef unsigned short     CMXYZComponent
  257. CMXYZColor                 RECORD    0
  258. X                         ds.w   1        ; offset: $0 (0)
  259. Y                         ds.w   1        ; offset: $2 (2)
  260. Z                         ds.w   1        ; offset: $4 (4)
  261. sizeof                     EQU *            ; size:   $6 (6)
  262.                         ENDR
  263.  
  264. ; typedef struct CMXYZColor  CMXYZColor
  265. CM2Header                 RECORD    0
  266. size                     ds.l   1        ; offset: $0 (0)        ; This is the total size of the Profile 
  267. CMMType                     ds.l   1        ; offset: $4 (4)        ; CMM signature,  Registered with CS2 consortium  
  268. profileVersion             ds.l   1        ; offset: $8 (8)        ; Version of CMProfile format 
  269. profileClass             ds.l   1        ; offset: $C (12)        ; input, display, output, devicelink, abstract, or color conversion profile type 
  270. dataColorSpace             ds.l   1        ; offset: $10 (16)        ; color space of data 
  271. profileConnectionSpace     ds.l   1        ; offset: $14 (20)        ; profile connection color space 
  272. dateTime                 ds     CMDateTime ; offset: $18 (24)    ; date and time of profile creation 
  273. CS2profileSignature         ds.l   1        ; offset: $24 (36)        ; 'acsp' constant ColorSync 2.0 file ID 
  274. platform                 ds.l   1        ; offset: $28 (40)        ; primary profile platform, Registered with CS2 consortium 
  275. flags                     ds.l   1        ; offset: $2C (44)        ; profile flags 
  276. deviceManufacturer         ds.l   1        ; offset: $30 (48)        ; Registered with CS2 consortium 
  277. deviceModel                 ds.l   1        ; offset: $34 (52)        ; Registered with CS2 consortium 
  278. deviceAttributes         ds.l   2        ; offset: $38 (56)        ; Attributes like paper type 
  279. renderingIntent             ds.l   1        ; offset: $40 (64)        ; preferred rendering intent of tagged object 
  280. white                     ds     CMFixedXYZColor ; offset: $44 (68) ; profile illuminant 
  281. reserved                 ds.b   48        ; offset: $50 (80)        ; reserved for future use 
  282. sizeof                     EQU *            ; size:   $80 (128)
  283.                         ENDR
  284.  
  285. ; typedef struct CM2Header     CM2Header
  286. CMTagRecord             RECORD    0
  287. tag                         ds.l   1        ; offset: $0 (0)        ; Registered with CS2 consortium 
  288. elementOffset             ds.l   1        ; offset: $4 (4)        ; Relative to start of CMProfile 
  289. elementSize                 ds.l   1        ; offset: $8 (8)
  290. sizeof                     EQU *            ; size:   $C (12)
  291.                         ENDR
  292.  
  293. ; typedef struct CMTagRecord  CMTagRecord
  294. CMTagElemTable             RECORD    0
  295. count                     ds.l   1        ; offset: $0 (0)
  296. tagList                     ds     CMTagRecord ; offset: $4 (4)    ; Variable size 
  297. sizeof                     EQU *            ; size:   $10 (16)
  298.                         ENDR
  299.  
  300. ; typedef struct CMTagElemTable  CMTagElemTable
  301. ; External 0x02002001 CMProfile 
  302. CM2Profile                 RECORD    0
  303. header                     ds     CM2Header ; offset: $0 (0)
  304. tagTable                 ds     CMTagElemTable ; offset: $80 (128)
  305. elemData                 ds.b   1        ; offset: $90 (144)        ; Tagged element storage. Variable size 
  306.                          ORG 146
  307. sizeof                     EQU *            ; size:   $92 (146)
  308.                         ENDR
  309.  
  310. ; typedef struct CM2Profile  CM2Profile, **CM2ProfileHandle
  311. ; Tag Type Definitions 
  312. CMCurveType             RECORD    0
  313. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'curv' 
  314. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  315. countValue                 ds.l   1        ; offset: $8 (8)        ; number of entries in table that follows 
  316. data                     ds.w   1        ; offset: $C (12)        ; Tagged element storage. Variable size 
  317. sizeof                     EQU *            ; size:   $E (14)
  318.                         ENDR
  319.  
  320. ; typedef struct CMCurveType  CMCurveType
  321. CMDataType                 RECORD    0
  322. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'data' 
  323. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  324. dataFlag                 ds.l   1        ; offset: $8 (8)        ; 0 = ASCII, 1 = binary 
  325. data                     ds.b   1        ; offset: $C (12)        ; Tagged element storage. Variable size 
  326.                          ORG 14
  327. sizeof                     EQU *            ; size:   $E (14)
  328.                         ENDR
  329.  
  330. ; typedef struct CMDataType  CMDataType
  331. CMDateTimeType             RECORD    0
  332. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'dtim' 
  333. reserved                 ds.l   1        ; offset: $4 (4)
  334. dateTime                 ds     CMDateTime ; offset: $8 (8)
  335. sizeof                     EQU *            ; size:   $14 (20)
  336.                         ENDR
  337.  
  338. ; typedef struct CMDateTimeType  CMDateTimeType
  339. CMLut16Type             RECORD    0
  340. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'mft2' 
  341. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  342. inputChannels             ds.b   1        ; offset: $8 (8)        ; Number of input channels 
  343. outputChannels             ds.b   1        ; offset: $9 (9)        ; Number of output channels 
  344. gridPoints                 ds.b   1        ; offset: $A (10)        ; Number of clutTable grid points 
  345. reserved2                 ds.b   1        ; offset: $B (11)        ; fill with 0x00 
  346. matrix                     ds.l   9        ; offset: $C (12)        ; 
  347. inputTableEntries         ds.w   1        ; offset: $30 (48)        ; 
  348. outputTableEntries         ds.w   1        ; offset: $32 (50)        ; 
  349. inputTable                 ds.w   1        ; offset: $34 (52)        ; Variable size 
  350. CLUT                     ds.w   1        ; offset: $36 (54)        ; Variable size 
  351. outputTable                 ds.w   1        ; offset: $38 (56)        ; Variable size 
  352. sizeof                     EQU *            ; size:   $3A (58)
  353.                         ENDR
  354.  
  355. ; typedef struct CMLut16Type  CMLut16Type
  356. CMLut8Type                 RECORD    0
  357. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'mft1' 
  358. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  359. inputChannels             ds.b   1        ; offset: $8 (8)        ; 
  360. outputChannels             ds.b   1        ; offset: $9 (9)        ; 
  361. gridPoints                 ds.b   1        ; offset: $A (10)        ; 
  362. reserved2                 ds.b   1        ; offset: $B (11)        ; fill with 0x00 
  363. matrix                     ds.l   9        ; offset: $C (12)        ; 
  364. inputTable                 ds.b   256        ; offset: $30 (48)        ; fixed size of 256 
  365. CLUT                     ds.b   1        ; offset: $130 (304)    ; Variable size 
  366. outputTable                 ds.b   256        ; offset: $131 (305)    ; fixed size of 256 
  367.                          ORG 562
  368. sizeof                     EQU *            ; size:   $232 (562)
  369.                         ENDR
  370.  
  371. ; typedef struct CMLut8Type  CMLut8Type
  372. CMMeasurementType         RECORD    0
  373. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'meas' 
  374. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  375. standardObserver         ds.l   1        ; offset: $8 (8)        ; 0 : unknown, 1 : CIE 1931, 2 : CIE 1964 
  376. backingXYZ                 ds     CMFixedXYZColor ; offset: $C (12) ; absolute XYZ values of backing 
  377. geometry                 ds.l   1        ; offset: $18 (24)        ; 0 : unknown, 1 : 0/45 or 45/0, 2 :0/d or d/0 
  378. flare                     ds.l   1        ; offset: $1C (28)        ; 0 : 0%, 1 : 100% flare 
  379. illuminant                 ds.l   1        ; offset: $20 (32)        ; standard illuminant 
  380. sizeof                     EQU *            ; size:   $24 (36)
  381.                         ENDR
  382.  
  383. ; typedef struct CMMeasurementType  CMMeasurementType
  384. CMNamedColorType         RECORD    0
  385. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'ncol' 
  386. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  387. vendorFlag                 ds.l   1        ; offset: $8 (8)        ; 
  388. count                     ds.l   1        ; offset: $C (12)        ; count of named colors in array that follows 
  389. prefixName                 ds.b   1        ; offset: $10 (16)        ; Variable size, max = 32, to access fields after this one, have to count bytes 
  390. suffixName                 ds.b   1        ; offset: $11 (17)        ; Variable size, max = 32 
  391. rootName                 ds.b   1        ; offset: $12 (18)        ; Variable size, max = 32 
  392. colorCoords                 ds.b   1        ; offset: $13 (19)        ; Variable size  
  393. sizeof                     EQU *            ; size:   $14 (20)
  394.                         ENDR
  395.  
  396. ; typedef struct CMNamedColorType  CMNamedColorType
  397. CMTextDescriptionType     RECORD    0
  398. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'desc' 
  399. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  400. ASCIICount                 ds.l   1        ; offset: $8 (8)        ; the count of "bytes" 
  401. ASCIIName                 ds.b   2        ; offset: $C (12)        ; Variable size, to access fields after this one, have to count bytes 
  402. UniCodeCode                 ds.l   1        ; offset: $E (14)
  403. UniCodeCount             ds.l   1        ; offset: $12 (18)        ; the count of characters, each character has two bytes 
  404. UniCodeName                 ds.b   2        ; offset: $16 (22)        ; Variable size 
  405. ScriptCodeCode             ds.w   1        ; offset: $18 (24)
  406. ScriptCodeCount             ds.b   1        ; offset: $1A (26)        ; the count of "bytes" 
  407. ScriptCodeName             ds.b   2        ; offset: $1B (27)        ; Variable size 
  408.                          ORG 30
  409. sizeof                     EQU *            ; size:   $1E (30)
  410.                         ENDR
  411.  
  412. ; typedef struct CMTextDescriptionType  CMTextDescriptionType
  413. CMTextType                 RECORD    0
  414. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'text' 
  415. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  416. text                     ds.b   1        ; offset: $8 (8)        ; count of text is obtained from tag size element 
  417.                          ORG 10
  418. sizeof                     EQU *            ; size:   $A (10)
  419.                         ENDR
  420.  
  421. ; typedef struct CMTextType  CMTextType
  422. CMScreeningType         RECORD    0
  423. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'scrn' 
  424. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  425. screeningFlag             ds.l   1        ; offset: $8 (8)        ; bit 0 : use printer default screens, bit 1 : inch/cm 
  426. channelCount             ds.l   1        ; offset: $C (12)
  427. frequency                 ds.l   1        ; offset: $10 (16)
  428. angle                     ds.l   1        ; offset: $14 (20)
  429. sportFunction             ds.l   1        ; offset: $18 (24)
  430. sizeof                     EQU *            ; size:   $1C (28)
  431.                         ENDR
  432.  
  433. ; typedef struct CMScreeningType  CMScreeningType
  434. CMSignatureType         RECORD    0
  435. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'sig ' 
  436. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  437. signature                 ds.l   1        ; offset: $8 (8)
  438. sizeof                     EQU *            ; size:   $C (12)
  439.                         ENDR
  440.  
  441. ; typedef struct CMSignatureType  CMSignatureType
  442. CMS15Fixed16ArrayType     RECORD    0
  443. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'sf32' 
  444. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  445. value                     ds.l   1        ; offset: $8 (8)        ; Variable size 
  446. sizeof                     EQU *            ; size:   $C (12)
  447.                         ENDR
  448.  
  449. ; typedef struct CMS15Fixed16ArrayType  CMS15Fixed16ArrayType
  450. CMU16Fixed16ArrayType     RECORD    0
  451. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'uf32' 
  452. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  453. value                     ds.l   1        ; offset: $8 (8)        ; Variable size 
  454. sizeof                     EQU *            ; size:   $C (12)
  455.                         ENDR
  456.  
  457. ; typedef struct CMU16Fixed16ArrayType  CMU16Fixed16ArrayType
  458. CMUInt16ArrayType         RECORD    0
  459. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'ui16' 
  460. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  461. value                     ds.w   1        ; offset: $8 (8)        ; Variable size 
  462. sizeof                     EQU *            ; size:   $A (10)
  463.                         ENDR
  464.  
  465. ; typedef struct CMUInt16ArrayType  CMUInt16ArrayType
  466. CMUInt32ArrayType         RECORD    0
  467. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'ui32' 
  468. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  469. value                     ds.l   1        ; offset: $8 (8)        ; Variable size 
  470. sizeof                     EQU *            ; size:   $C (12)
  471.                         ENDR
  472.  
  473. ; typedef struct CMUInt32ArrayType  CMUInt32ArrayType
  474. CMUInt64ArrayType         RECORD    0
  475. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'ui64' 
  476. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  477. value                     ds.l   1        ; offset: $8 (8)        ; Variable size (x2) 
  478. sizeof                     EQU *            ; size:   $C (12)
  479.                         ENDR
  480.  
  481. ; typedef struct CMUInt64ArrayType  CMUInt64ArrayType
  482. CMUInt8ArrayType         RECORD    0
  483. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'ui08' 
  484. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  485. value                     ds.b   1        ; offset: $8 (8)        ; Variable size 
  486.                          ORG 10
  487. sizeof                     EQU *            ; size:   $A (10)
  488.                         ENDR
  489.  
  490. ; typedef struct CMUInt8ArrayType  CMUInt8ArrayType
  491. CMViewingConditionsType RECORD    0
  492. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'view' 
  493. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  494. illuminant                 ds     CMFixedXYZColor ; offset: $8 (8) ; absolute XYZs of illuminant  in cd/m^2 
  495. surround                 ds     CMFixedXYZColor ; offset: $14 (20) ; absolute XYZs of surround in cd/m^2 
  496. stdIlluminant             ds.l   1        ; offset: $20 (32)        ; see definitions of std illuminants 
  497. sizeof                     EQU *            ; size:   $24 (36)
  498.                         ENDR
  499.  
  500. ; typedef struct CMViewingConditionsType  CMViewingConditionsType
  501. CMXYZType                 RECORD    0
  502. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'XYZ ' 
  503. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  504. XYZ                         ds     CMFixedXYZColor ; offset: $8 (8) ; variable size XYZ tristimulus values 
  505. sizeof                     EQU *            ; size:   $14 (20)
  506.                         ENDR
  507.  
  508. ; typedef struct CMXYZType     CMXYZType
  509. ; Profile sequence description type 
  510. CMProfileSequenceDescType RECORD    0
  511. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'pseq ' 
  512. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  513. count                     ds.l   1        ; offset: $8 (8)        ; Number of descriptions
  514. ;                                                         * variable size fields to follow, to access them, must count bytes 
  515. deviceMfg                 ds.l   1        ; offset: $C (12)        ; Device Manufacturer 
  516. deviceModel                 ds.l   1        ; offset: $10 (16)        ; Decvice Model 
  517. attributes                 ds.l   2        ; offset: $14 (20)        ; Device attributes 
  518. technology                 ds.l   1        ; offset: $1C (28)        ; Technology signature 
  519. mfgDescASCIICount         ds.l   1        ; offset: $20 (32)        ; the count of "bytes" 
  520. mfgDescASCIIName         ds.b   2        ; offset: $24 (36)        ; Variable size 
  521. mfgDescUniCodeCode         ds.l   1        ; offset: $26 (38)
  522. mfgDescUniCodeCount         ds.l   1        ; offset: $2A (42)        ; the count of characters, each character has two bytes 
  523. mfgDescUniCodeName         ds.b   2        ; offset: $2E (46)        ; Variable size 
  524. mfgDescScriptCodeCode     ds.l   1        ; offset: $30 (48)
  525. mfgDescScriptCodeCount     ds.l   1        ; offset: $34 (52)        ; the count of "bytes" 
  526. mfgDescScriptCodeName     ds.b   2        ; offset: $38 (56)        ; Variable size 
  527. modelDescASCIICount         ds.l   1        ; offset: $3A (58)        ; the count of "bytes" 
  528. modelDescASCIIName         ds.b   2        ; offset: $3E (62)        ; Variable size 
  529. modelDescUniCodeCode     ds.l   1        ; offset: $40 (64)
  530. modelDescUniCodeCount     ds.l   1        ; offset: $44 (68)        ; the count of characters, each character has two bytes 
  531. modelDescUniCodeName     ds.b   2        ; offset: $48 (72)        ; Variable size 
  532. modelDescScriptCodeCode     ds.w   1        ; offset: $4A (74)
  533. modelDescScriptCodeCount ds.b   1        ; offset: $4C (76)        ; the count of "bytes" 
  534. modelDescScriptCodeName     ds.b   2        ; offset: $4D (77)        ; Variable size 
  535. sizeof                     EQU *            ; size:   $50 (80)
  536.                         ENDR
  537.  
  538. ; typedef struct CMProfileSequenceDescType  CMProfileSequenceDescType
  539. ; Under color removal, black generation type 
  540. CMUcrBgType             RECORD    0
  541. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'bfd  ' 
  542. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  543. ucrCount                 ds.l   1        ; offset: $8 (8)        ; Number of UCR entries 
  544. ucrValues                 ds.w   1        ; offset: $C (12)        ; variable size 
  545. bgCount                     ds.l   1        ; offset: $E (14)        ; Number of BG entries 
  546. bgValues                 ds.w   1        ; offset: $12 (18)        ; variable size 
  547. ucrbgASCII                 ds.b   1        ; offset: $14 (20)        ; null terminated ASCII string 
  548.                          ORG 22
  549. sizeof                     EQU *            ; size:   $16 (22)
  550.                         ENDR
  551.  
  552. ; typedef struct CMUcrBgType  CMUcrBgType
  553. CMIntentCRDVMSize         RECORD    0
  554. renderingIntent             ds.l   1        ; offset: $0 (0)        ; rendering intent 
  555. VMSize                     ds.l   1        ; offset: $4 (4)        ; VM size taken up by the CRD 
  556. sizeof                     EQU *            ; size:   $8 (8)
  557.                         ENDR
  558.  
  559. ; typedef struct CMIntentCRDVMSize  CMIntentCRDVMSize
  560. CMPS2CRDVMSizeType         RECORD    0
  561. typeDescriptor             ds.l   1        ; offset: $0 (0)        ; 'psvm' 
  562. reserved                 ds.l   1        ; offset: $4 (4)        ; fill with 0x00 
  563. count                     ds.l   1        ; offset: $8 (8)        ; number of intent entries 
  564. intentCRD                 ds     CMIntentCRDVMSize ; offset: $C (12) ; variable size 
  565. sizeof                     EQU *            ; size:   $14 (20)
  566.                         ENDR
  567.  
  568. ; typedef struct CMPS2CRDVMSizeType  CMPS2CRDVMSizeType
  569. ;**********************************************************************
  570. ;************** ColorSync 1.0 profile specification *******************
  571. ;**********************************************************************
  572.  
  573. cmGrayResponse                    EQU        0
  574. cmRedResponse                    EQU        1
  575. cmGreenResponse                    EQU        2
  576. cmBlueResponse                    EQU        3
  577. cmCyanResponse                    EQU        4
  578. cmMagentaResponse                EQU        5
  579. cmYellowResponse                EQU        6
  580. cmUcrResponse                    EQU        7
  581. cmBgResponse                    EQU        8
  582. cmOnePlusLastResponse            EQU        9
  583.  
  584. ; Device types 
  585. cmMonitorDevice                    EQU        'mntr'
  586. cmScannerDevice                    EQU        'scnr'
  587. cmPrinterDevice                    EQU        'prtr'
  588.  
  589. CMIString                 RECORD    0
  590. theScript                 ds.w   1        ; offset: $0 (0)
  591. theString                 ds.l   16        ; offset: $2 (2)
  592. sizeof                     EQU *            ; size:   $42 (66)
  593.                         ENDR
  594.  
  595. ; typedef struct CMIString     CMIString
  596. ; Profile options 
  597.  
  598. cmPerceptualMatch                EQU        $0000                ; Default. For photographic images 
  599. cmColorimetricMatch                EQU        $0001                ; Exact matching when possible 
  600. cmSaturationMatch                EQU        $0002                ; For solid colors 
  601.  
  602. ; Profile flags 
  603. cmNativeMatchingPreferred        EQU        $00000001            ; Default to native not preferred 
  604. cmTurnOffCache                    EQU        $00000002            ; Default to turn on CMM cache 
  605.  
  606. ; typedef long                 CMMatchOption
  607. ; typedef long                 CMMatchFlag
  608. CMHeader                 RECORD    0
  609. size                     ds.l   1        ; offset: $0 (0)
  610. CMMType                     ds.l   1        ; offset: $4 (4)
  611. applProfileVersion         ds.l   1        ; offset: $8 (8)
  612. dataType                 ds.l   1        ; offset: $C (12)
  613. deviceType                 ds.l   1        ; offset: $10 (16)
  614. deviceManufacturer         ds.l   1        ; offset: $14 (20)
  615. deviceModel                 ds.l   1        ; offset: $18 (24)
  616. deviceAttributes         ds.l   2        ; offset: $1C (28)
  617. profileNameOffset         ds.l   1        ; offset: $24 (36)
  618. customDataOffset         ds.l   1        ; offset: $28 (40)
  619. flags                     ds.l   1        ; offset: $2C (44)
  620. options                     ds.l   1        ; offset: $30 (48)
  621. white                     ds     CMXYZColor ; offset: $34 (52)
  622. black                     ds     CMXYZColor ; offset: $3A (58)
  623. sizeof                     EQU *            ; size:   $40 (64)
  624.                         ENDR
  625.  
  626. ; typedef struct CMHeader     CMHeader
  627. CMProfileChromaticities RECORD    0
  628. red                         ds     CMXYZColor ; offset: $0 (0)
  629. green                     ds     CMXYZColor ; offset: $6 (6)
  630. blue                     ds     CMXYZColor ; offset: $C (12)
  631. cyan                     ds     CMXYZColor ; offset: $12 (18)
  632. magenta                     ds     CMXYZColor ; offset: $18 (24)
  633. yellow                     ds     CMXYZColor ; offset: $1E (30)
  634. sizeof                     EQU *            ; size:   $24 (36)
  635.                         ENDR
  636.  
  637. ; typedef struct CMProfileChromaticities  CMProfileChromaticities
  638. CMProfileResponse         RECORD    0
  639. counts                     ds.w   9        ; offset: $0 (0)
  640. data                     ds.w   1        ; offset: $12 (18)        ; Variable size 
  641. sizeof                     EQU *            ; size:   $14 (20)
  642.                         ENDR
  643.  
  644. ; typedef struct CMProfileResponse  CMProfileResponse
  645. CMProfile                 RECORD    0
  646. header                     ds     CMHeader ; offset: $0 (0)
  647. profile                     ds     CMProfileChromaticities ; offset: $40 (64)
  648. response                 ds     CMProfileResponse ; offset: $64 (100)
  649. profileName                 ds     CMIString ; offset: $78 (120)
  650. customData                 ds.b   1        ; offset: $BA (186)        ; Variable size 
  651.                          ORG 188
  652. sizeof                     EQU *            ; size:   $BC (188)
  653.                         ENDR
  654.  
  655. ; typedef struct CMProfile     CMProfile, **CMProfileHandle
  656.     IF OLDROUTINENAMES  THEN
  657.  
  658. kCMApplProfileVersion            EQU        cmCS1ProfileVersion
  659.  
  660. grayResponse                    EQU        cmGrayResponse
  661. redResponse                        EQU        cmRedResponse
  662. greenResponse                    EQU        cmGreenResponse
  663. blueResponse                    EQU        cmBlueResponse
  664. cyanResponse                    EQU        cmCyanResponse
  665. magentaResponse                    EQU        cmMagentaResponse
  666. yellowResponse                    EQU        cmYellowResponse
  667. ucrResponse                        EQU        cmUcrResponse
  668. bgResponse                        EQU        cmBgResponse
  669. onePlusLastResponse                EQU        cmOnePlusLastResponse
  670.  
  671. rgbData                            EQU        cmRGBData
  672. cmykData                        EQU        cmCMYKData
  673. grayData                        EQU        cmGrayData
  674. xyzData                            EQU        cmXYZData
  675.  
  676. monitorDevice                    EQU        cmMonitorDevice
  677. scannerDevice                    EQU        cmScannerDevice
  678. printerDevice                    EQU        cmPrinterDevice
  679.  
  680. ; typedef unsigned short     XYZComponent
  681. ; typedef struct CMXYZColor  XYZColor
  682. ; typedef unsigned short     CMResponseData
  683. ; typedef struct CMIString     IString
  684. ; typedef long                 CMResponseColor
  685. ; typedef CMResponseColor     responseColor
  686.     ENDIF
  687.     ENDIF ; __CMICCPROFILE__
  688.